Skip to content

Upgrade to sbt 1.2.3, properly report problems to sbt #5106

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Sep 14, 2018

Conversation

smarter
Copy link
Member

@smarter smarter commented Sep 14, 2018

No description provided.

@smarter smarter force-pushed the proper-sbt-reporting-3 branch 2 times, most recently from 1b761b6 to 10d1cdb Compare September 14, 2018 09:07
@@ -928,6 +928,7 @@ object Build {
// sbt plugin to use Dotty in your own build, see
// https://github.com/lampepfl/dotty-example-project for usage.
lazy val `sbt-dotty` = project.in(file("sbt-dotty")).
enablePlugins(ScriptedPlugin).
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we use the newer SbtPlugin?

@allanrenucci
Copy link
Contributor

We should experiment with sbt/sbt#3891. It introduces two new options to the scripted tests:

  • scriptedBatchExecution (Boolean): Enables or disables batch execution for scripted.
  • scriptedParallelInstances (Int): Configures the number of scripted instances for parallel testing, only used in batch mode.

@smarter smarter force-pushed the proper-sbt-reporting-3 branch 3 times, most recently from ca685e8 to 9a96668 Compare September 14, 2018 11:28
We cannot use sbtVersion.value for compiler-interface and zinc-api-info
anymore because sbt 1.2.3 uses Zinc 1.2.2
@smarter smarter force-pushed the proper-sbt-reporting-3 branch 2 times, most recently from 3af53c8 to 4800292 Compare September 14, 2018 12:35
@smarter
Copy link
Member Author

smarter commented Sep 14, 2018

We're getting a ClassCastException in the scripted test but it's probably harmless: sbt/sbt#4361

@smarter
Copy link
Member Author

smarter commented Sep 14, 2018

scriptedBatchExecution (Boolean): Enables or disables batch execution for scripted.

sbt.internal.scripted.TestException: {line -1} Reload for scripted batch execution failed.

Looks like a no go.

@smarter
Copy link
Member Author

smarter commented Sep 14, 2018

Also before that there is:

[error] Error: Could not find or load main class sbt.RunFromSourceMain

@allanrenucci
Copy link
Contributor

Too bad. No speedup for the scripted tests then...

The new image has updated dependencies and is based on Ubuntu instead of
Alpine.
Dotty has its own logic for displaying problems with the proper file
path, position, and caret, but if we store this information in
Problem#message we end up with duplicated information in the output
since Zinc will prepend/append similar things (see
sbt.internal.inc.ProblemStringFormats). So far, we worked around this in
Dotty by using an empty position in the sbt bridge reporter, but this
means that crucial semantic information that could be used by a Build
Server Protocol implementation and other tools is lost.

Thanks to sbt/zinc#588 we can now fully
customize how the message is displayed to the user using
Problem#rendered, so we can now store the position information without
any adverse effect.
@smarter smarter force-pushed the proper-sbt-reporting-3 branch 2 times, most recently from e090a29 to cbff210 Compare September 14, 2018 13:36
@smarter smarter merged commit fb655f7 into scala:master Sep 14, 2018
@allanrenucci allanrenucci deleted the proper-sbt-reporting-3 branch September 14, 2018 16:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants